Developer --> Technical Publications
PATH  Mac OS X Server Documentation > Mac OS X Server Release Notes


[Back]

MacOS X Server Release Notes Copyright \xa9 1998 by Apple Computer, Inc. All Rights Reserved.

Mac OS X Server Developer Release Notes:
Debugging

This file contains release notes for the Customer Release 1 of the gdb and jdb command-line debuggers, and of the Project Builder visual debugging facilities. The section in this document are:

gdb
A command-line debugger for C, Objective-C, and C++ programs
jdb
A command-line debugger for Java applets and 100% Pure JavaTM programs
Project Builder
Visual debugging for C, Objective-C, and C++ programs using gdb and Java debugging using the Java debugger.

GDB Versions

The version of gdb for Yellow Box for Windows is based on GDB version 4.16, released on April 22, 1996 by the Free Software Foundation (FSF). This is the same version of GDB that shipped with the Yellow Box for Windows Developer Release.

Two versions of gdb are shipped with the Rhapsody release. The first, /usr/bin/gdb-4.14, is based on GDB version 4.14, released on March 8, 1995 by the Free Software Foundation (FSF), and is the same version of GDB that shipped with Rhapsody DR1 and Rhapsody DR2.

The second, /usr/bin/gdb-4.17, is based on GDB version 4.17, released on April 24, 1998 by Cygnus Solutions (Cygnus). Although still a bit immature, this newer version of gdb offers better support areas such as signal handling, attaching to running processes, and dynamic library loading, as well as a number of bug fixes.

This version of GDB currently used by default is /usr/bin/gdb-4.17, installed as the default via a symbolic link from /usr/bin/gdb to /usr/bin/gdb-4.17. To change the default gdb to gdb-4.14, execute the following command as root:

ln -sf gdb-4.14 /usr/bin/gdb

To change back to using gdb-4.17 as the default, use the following command (also as root):

ln -sf gdb-4.17 /usr/bin/gdb

 

Additional Documentation

On Rhapsody Systems, a summary of command-line options for gdb is available via the manual page for gdb (1).

For more information on gdb-4.14, see the documentation in /System/Documentation/Developer/YellowBox/Reference/DevTools/Debugger . For release notes on gdb-4.14, see the gdb-4.14 release note.

For more information on gdb-4.17, see the documentation in /System/Documentation/Developer/Commands/gdb/gdb. Release notes for gdb-4.17 are in this document.

A single-page gdb-4.17 reference card, suitable for printing, is available in both PostScript and in PDF format. For those interested in the internal workings of gdb-4.17, complete source code is available either via the Source CD, or via FTP.

For the most up-to-date information on either version GDB, see the Rhapsody Developer Release website on the Apple Developer web site. Updates to gdb-4.14 and gdb-4.17 will be posted here as they become available.

Significant Changes from gdb-4.14 to gdb-4.17

Known Problems in gdb-4.17

Notes Specific to jdb

New Features

The jdb command-line debugger from JavaSoft is included in the Developer Release 2 of both Rhapsody and Yellow Box for Windows. You can find the documentation for jdb Rhapsody at:

http://java.sun.com/products/jdk/1.1/docs/tooldocs/solaris/jdb.html

and for Windows at:

http://java.sun.com/products/jdk/1.1/docs/tooldocs/win32/jdb.html

 

Known Problems

jdb Does not Work With "Pure Yellow Box Java"

Yellow Box Java applications, that is, those that subclass from NSPureApplication and are started with the java command, do not work with jdb. For example, this command fails:

jdb com.apple.yellow.application.NSPureApplication -YBJavaApplicationPath /<wherever>/TextEdit.app"
 

Notes Specific to Project Builder Debugging

Project Builder provides integrated, visual debugging of programs through the Launcher panel (). This panel can be used to run or debug executables built by your project.

Notes on Using Java

There is a new tutorial for developing Yellow Box Java Applications (<Link TO Terrys Tutorial>); this document describes how to use InterfaceBuilder and ProjectBuilder to create and manage Java applications. Here are view hints regarding debugging Java

New Features for CR1

Known Problems

Only Debug Yellow Box Java Applications

There is no debugging support for Java applets or 100% Pure Java applications.

 

Setting Breakpoints Before Running

You cannot set breakpoints in Java code before the debugger is running. As the Java VM starts up, there is a race condition between the starting of the debugger and the starting of the application. Therefore, some of your code will execute before the debugger becomes active and you are not able to set a breakpoint in this code.

 

No mixed stack backtrace

The stack back trace from the Java debugger includes only Java frames. Calls to native methods are not shown.

 

 

New Features for DR2

The following new features have been added to Project Builder for debugging since the Developer Release.